<!-- 添加订单成功 -->
<div id="addorder" style="width:25%;z-index:999;position:fixed;top:30%;left:40%;border-radius: 16px;box-shadow: 0 0 6px 3px rgba(0,0,0,.15);padding: 10px 20px;background-color: #e8edef;display:none;">
    <style type="text/css">
        .successfullyfrom-close-r{float:right}
        .successfullyfrom-close-r button{border:none;background-color: #FDD702;color:black;font-weight:bold;border-radius:5px;cursor:pointer;font-size:16px;padding:3px 6px;border-radius: 5px;}
        .successfullyfrom-close-r button:hover{background-color:#36648a;color:#ffffff}
        .successfullyfrom-close-b{padding:10px 12px;}
        .successfullyfrom-close-b button{border:none;background-color: #FDD702;color:black;font-weight:bold;border-radius:5px;cursor:pointer;font-size:16px;padding:5px 10px;border-radius: 5px;}
        .successfullyfrom-close-b button:hover{background-color:#36648a;color:#ffffff}
    </style>
    <div  class="successfullyfrom-close-r"><button type="button" onclick="close_successfullyfrom()">X</button></div>
    <h2 style="font-size:30px;color:#36648a;padding:20px 10px;line-height:32px;">Order Prompt</h2>
    <div style="font-size:16px;color:#79858e;padding:10px;line-height:20px;">The order is added successfully. You can click <a href="/order/">order</a> to pay or view</div>
    <div class="successfullyfrom-close-b"><button type="button" onclick="close_successfullyfrom()">close</button></div>
</div>
<!-- 脚部 -->
<?php $lang=config('app.default_lang');?>
<style>
    @media screen and (min-width: 768px) {
        .zh-icon:hover .QRcode{
            display:block;
        }
    }
    .QRcode{
        width: 130px;
        position: absolute;
        z-index: 99;
        display:none;
    }
    .zh-buttom-img{
        display: flex;
    }
    .zh-icon{
        margin: 0 5px;
    }
    .zh-icon a>img, .zh-icon>img{
        width: 80%;
        border-radius: 25%;
    }
    .QRcode img{
        width: 80%;
    }
</style>


<!-- end 脚部 -->

<script data-cfasync="false" src="/cdn-cgi/scripts/5c5dd728/cloudflare-static/email-decode.min.js"></script>

<script src="/static/js/jquery-2.1.4.min.js"></script>

<script src="/static/js/nav.js" type="text/javascript"></script><!--导航js-->

<script src="/static/layui/layui.js" charset="utf-8"></script>


<script type="text/javascript">
    //导航 js

    $(function () {
        $("#main-menu").smartmenus({

            subMenusSubOffsetX: 6,

            subMenusSubOffsetY: -8,

        });

    });

    // SmartMenus mobile menu toggle button

    $(function () {

        var $mainMenuState = $("#main-menu-state");

        if ($mainMenuState.length) {

            // animate mobile menu

            $mainMenuState.change(function (e) {

                var $menu = $("#main-menu");

                if (this.checked) {

                    $menu.hide().slideDown(250, function () {

                        $menu.css("display", "block");
                        $(".Products-nav").children(1).css("display", "block");
                        $('.Products-nav').children('.has-submenu').prop('class','has-submenu highlighted');
                    });

                } else {

                    $menu.show().slideUp(250, function () {

                        $menu.css("display", "none");

                    });

                }

            });

            // hide mobile menu beforeunload

            $(window).bind("beforeunload unload", function () {

                if ($mainMenuState[0].checked) {

                    $mainMenuState[0].click();

                }

            });

        }

    });



    /*轮播*/



    layui.use(["carousel", "form","element",'layer'], function () {

        var carousel = layui.carousel,

            form = layui.form,

            element = layui.element;

        var $ = layui.jquery, layer = layui.layer;

        //图片轮播



        var lunbo=carousel.render({

            elem: "#lunbo",

            width: "100%",

            height: "820px",

            interval: 5000,

        });

        carousel.on('change(carofilter)', function(obj){ //监听轮播

            var screen_width=$(window).width();//屏幕宽度

            if(screen_width<='768'){

                lunbo.reload({ //重置轮播

                    elem: '#lunbo',

                    width: "100%", //设置容器宽度

                    height: '260px',

                    interval: 5000,

                });

                $('.pic').css('height','100%');

            }

        });



    });





    /*点击切换语言*/

    function lan_qihuan2(){
        $(".qlang-sechond").css('display','block');
    }

    function qlang_hover(){
        $("#qlang-sechond-l1").css('background','#ffffff');
        $("#qlang-sechond-l1 a").css('color','black');
        $("#qlang-sechond-l1 i").css('color','#ffffff');
    }
    function qlang_hover_out(){
        $("#qlang-sechond-l1").css('background','#36648a');
        $("#qlang-sechond-l1 a").css('color','#ffffff');

    }

    $(document).mouseup(function(e) {
        var _con = $('#qlang');
        if( !_con.is(e.target) && _con.has(e.target).length === 0 ){
            $('#qlang-sechond').css('display','none');
        }
    });


    /*搜索*/
    <?php if($lang=='en-us'){?>
        var url_str=window.location.pathname; //这是一字符串
        var strs= new Array(); //定义一数组

        strs=url_str.split("/"); //字符分割

        if(strs[1]=='search-result'){

            var issearapi=1;

        }else{

            var issearapi=2;

        }





        function searsel(){

            var index = layer.load(1, { shade: [0.1,'#fff'] });

            var title = $.trim($('#sear').val());

            if(title==''){

                $("#layui-icon-search").css('display','inline');

                $("#layui-icon-close").css('display','none');

                $("#selinfo").css('display',"none");

                $("#sear").val('');

                $("#selinfo").html('');

                layer.closeAll('loading');

                return false;

            }



            $.post("{:url('index/Es/get_search')}",{searinfo:title},function(res){
                var resdata=res.hits;

                if(resdata.total==0){
                    layer.closeAll('loading');
                    $("#layui-icon-close").css('display','inline');
                    return false;
                }else{
                    var str='';
                    for(var i=0;i<resdata.hits.length;i++){
                        str += '<div class="sear-tips-result-body"><div class="sear-tips-result-header">';
                        str += '<h3><a onclick="tongji(\''+resdata.hits[i]['_source']['Product_Number']+'\',\'1\')" href="/products/'+resdata.hits[i]['_source']['url']+'/">'+resdata.hits[i]['_source']['Product_Number']+'</a></h3>';
                        str += '<span class="sear-tips-result-header-span"><span>In</span> <span>'+resdata.hits[i]['_source']['cname']+'</span></span></div>';
                        str += '<div class="sear-tips-result-content">';
                        str += '<div class="sear-tips-result-content1">'+resdata.hits[i]['_source']['neirong'].substring(0,300)+'</div>';
                        str += '<div class="sear-tips-result-content2">';
                        str += '<img src="'+resdata.hits[i]['_source']['img']+'">';
                        str += '</div> <div class="clear"></div></div></div>';
                    }
                    $('#selinfo').html(str);

                    $("#selinfo").css('display',"block");

                    $("#layui-icon-close").css('display','inline');

                    layer.closeAll('loading');
                }
            })


        }

        function tongji(title,type){
            var search_content = $.trim($('#sear').val());
            $.post("{:url('index/Es/tongji')}",{title:title,type:type,search_content:search_content},function(res){})
        }



        function closear(){

            $("#sear").val('');

            $("#selinfo").css('display','none');

            $("#selinfo").html('');

            $("#layui-icon-search").css('display','inline');

            $("#layui-icon-close").css('display','none');

        }



        function goout(){

            $("#selinfo").css('display','none');

        }

        function lai(){

            if(document.getElementById("selinfo").innerHTML==''){

                $("#selinfo").css('display','none');

            }else{

                $("#selinfo").css('display','block');

            }

        }


        var retlist='';

        document.onkeydown=function(event){



            var e = event || window.event || arguments.callee.caller.arguments[0];


            if(e && e.keyCode==13){ // enter 键

                $("#selinfo").css('display','none');

                sear();

            }

        };



        function sear(){

            var title = $.trim($('#sear').val());

            if(title==''){

                $("#layui-icon-search").css('display','inline');

                $("#layui-icon-close").css('display','none');

                $("#selinfo").css('display',"none");

                $("#sear").val('');

                $("#selinfo").html('');

                layer.closeAll('loading');

                return false;

            }

            // var v=title.replace(/ /g, '-').replace(/\//g,'-').replace(/\+/g, '-').replace(/\./g, '-');

            if(issearapi=='2'){

                location.href="/sr/"+title.toLowerCase()+"/";

            }else{

                location.href="/sr/"+title.toLowerCase()+"/";

            }

        }
        <?php } ?>
    <?php if($lang=='zh-cn'){?>
        var url_str=window.location.pathname; //这是一字符串

        var strs= new Array(); //定义一数组

        strs=url_str.split("/"); //字符分割

        if(strs[1]=='search-result'){

            var issearapi=1;

        }else{

            var issearapi=2;

        }



        var t=-1;//键盘改变根据值

        function searsel(){

            var index = layer.load(1, { shade: [0.1,'#fff'] });

            t=-1;

            var title = $.trim($('#sear').val());

            if(title==''){

                $("#layui-icon-search").css('display','inline');

                $("#layui-icon-close").css('display','none');

                $("#selinfo").css('display',"none");

                $("#sear").val('');

                $("#selinfo").html('');

                layer.closeAll('loading');

                return false;

            }
            $.post("{:url('index/Index/search_pr')}",{search:title},function(res){
                if(res.count=='0'){
                    layer.closeAll('loading');
                    $("#layui-icon-search").css('display','none');
                    $("#layui-icon-close").css('display','inline');
                    return false;
                }else{
                    var str='';
                    for(var i=0;i<res.data.length;i++){
                        str += '<input onclick="selinput(\''+res.data[i]['Product_Number']+'\')" readonly="readonly" value="'+res.data[i]['Product_Number']+'" id="tlist'+i+'">';
                    }
                    $('#selinfo').html(str);
                    $("#selinfo").css('display',"block");
                    $("#layui-icon-search").css('display','none');
                    $("#layui-icon-close").css('display','inline');
                    layer.closeAll('loading');
                }
            })

        }



        function selinput(d){

            var v=d.toLowerCase();

            $("#sear").val(v);



            if(issearapi=='1'){

                sear();

            }else{

                var v=v.replace(/ /g, '-').replace(/\//g,'-').replace(/\+/g, '-').replace(/\./g, '-');

                window.open("/search-result/"+v+"/");

            }

        }



        function closear(){

            $("#sear").val('');

            $("#selinfo").css('display','none');

            $("#selinfo").html('');

            $("#layui-icon-search").css('display','inline');

            $("#layui-icon-close").css('display','none');

        }



        function goout(){

            $("#selinfo").css('display','none');

        }

        function lai(){

            if(document.getElementById("selinfo").innerHTML==''){

                $("#selinfo").css('display','none');

            }else{

                $("#selinfo").css('display','block');

            }

        }



        var retlist='';

        document.onkeydown=function(event){



            var e = event || window.event || arguments.callee.caller.arguments[0];



            if(e.keyCode==38 || e.keyCode==40){

                e.preventDefault();

                if(document.getElementById('selinfo').style.display=='block'){

                    if(e.keyCode==38){

                        t--;

                        if(t<0){t=document.getElementById('selinfo').children.length-1;}

                    }

                    if(e.keyCode==40){

                        t++;

                        if(t>=document.getElementById('selinfo').children.length){t=0;}

                    }

                    $('#sear').val('');

                    document.getElementById('tlist'+t).focus();

                    for(var j=0;j<document.getElementById('selinfo').children.length; j++){

                        if(document.getElementById('selinfo').children.length.id!='tlist'+t){

                            $('#tlist'+j).css('background-color','#ffffff');

                            $('#tlist'+j).css('color','black');

                        }

                    }

                    $('#tlist'+t).css('background-color','#36648A');

                    $('#tlist'+t).css('color','#ffffff');

                    retlist = document.getElementById('tlist'+t);

                    $('#sear').val(retlist.value)



                }

            }



            if(e && e.keyCode==13){ // enter 键

                $("#selinfo").css('display','none');

                sear();

            }

        };



        function sear(){

            var title = $.trim($('#sear').val());

            if(title==''){

                $("#layui-icon-search").css('display','inline');

                $("#layui-icon-close").css('display','none');

                $("#selinfo").css('display',"none");

                $("#sear").val('');

                $("#selinfo").html('');

                layer.closeAll('loading');

                return false;

            }

            var v=title.replace(/ /g, '-').replace(/\//g,'-').replace(/\+/g, '-').replace(/\./g, '-');

            if(issearapi=='2'){

                location.href="/search-result/"+v.toLowerCase()+"/";

            }else{

                location.href="/search-result/"+v.toLowerCase()+"/";

            }

        }
        <?php } ?>
</script>

<script type="text/javascript">
    /*添加订单*/
    function detail_order_input(){
        var order_num=$.trim($("#detail-order-input").val());
        if(order_num === "" || order_num ==null || order_num==0){
            layer.tips('Please fill in the quantity', '#detail-order-input', {
                tips: [4, '#5FB878'],
            });
            document.getElementById("detail-order-input").focus();
            return false;
        }
        var reg = /^[0-9]*$/;
        if (!reg.test(order_num)) {
            layer.tips('The quantity filled in is incorrect', '#detail-order-input', {
                tips: [4, '#5FB878'],
            });
            document.getElementById("detail-order-input").focus();
            return false;
        }

        $.post('/order/add/',{Product_Number:Product_Number,order_num:order_num},function(res){
            if(res.status==1){
                $("#detail-order-input").val('');
                $("#order_num_change").html(res.count);
                $('#addorder').css('display','block');
                $('#body-zhe').css('display','block');
                $('#body-zhe').css('opacity','0.6');
                $('#body-zhe').css('transition','all 1s');
            }
        })
    }

    function close_successfullyfrom(){
        $('#addorder').css('display','none');
        $('#body-zhe').css('display','none');
    }

    $(document).ready(function(){

        $("body").click(function(){

            $('#addorder').css('display','none');
            $('#body-zhe').css('display','none');

        });

    });
</script>

<!-- 站外代码 -->


<?php if($lang=='en-us'){?>

<!-- Start of LiveChat (www.livechatinc.com) code -->
<script>
    var online_group_id='';
    function get_dynamic_configuration_group(){
      $.ajax({
        type: 'GET',
        url:"https://api.livechatinc.com/v3.5/customer/action/get_dynamic_configuration?license_id=3911741",
        async:false,
        success:function(res){
          if(res.online_group_ids.length<2){
            online_group_id=res.online_group_ids[0];
          }else{
            online_group_id=res.online_group_ids[1];
          }
        }
      });
      return online_group_id;
    }
    online_group_id=get_dynamic_configuration_group();
    window.__lc = window.__lc || {};
    window.__lc.license = 3911741;
    if(online_group_id!='0'){
      window.__lc.group = online_group_id;
    }
    ;(function(n,t,c){function i(n){return e._h?e._h.apply(null,n):e._q.push(n)}var e={_q:[],_h:null,_v:"2.0",on:function(){i(["on",c.call(arguments)])},once:function(){i(["once",c.call(arguments)])},off:function(){i(["off",c.call(arguments)])},get:function(){if(!e._h)throw new Error("[LiveChatWidget] You can't use getters before load.");return i(["get",c.call(arguments)])},call:function(){i(["call",c.call(arguments)])},init:function(){var n=t.createElement("script");n.async=!0,n.type="text/javascript",n.src="https://cdn.livechatinc.com/tracking.js",t.head.appendChild(n)}};!n.__lc.asyncInit&&e.init(),n.LiveChatWidget=n.LiveChatWidget||e}(window,document,[].slice))

      function liveChat_lily_click(){ /*主动唤起livechat*/
        LiveChatWidget.call('maximize');
      }
</script>

<noscript><a href="https://www.livechatinc.com/chat-with/3911741/" rel="nofollow">Chat with us</a>, powered by <a href="https://www.livechatinc.com/?welcome" rel="noopener nofollow" target="_blank">LiveChat</a></noscript>

<!-- End of LiveChat code -->



<!-- Matomo -->

<!-- <script type="text/javascript">

  var _paq = window._paq || [];

  _paq.push(['trackPageView']);

  _paq.push(['enableLinkTracking']);

  (function() {

    var u="https://lilybearing.matomo.cloud/";

    _paq.push(['setTrackerUrl', u+'matomo.php']);

    _paq.push(['setSiteId', '1']);

    var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];

    g.type='text/javascript'; g.async=true; g.defer=true; g.src='//cdn.matomo.cloud/lilybearing.matomo.cloud/matomo.js'; s.parentNode.insertBefore(g,s);

  })();

</script> -->

<!-- End Matomo Code -->





<!-- 触脉统计代码-->

<script>

    (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){

        (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),

        m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)

    })(window,document,'script','//www.google-analytics.com/analytics.js','ga');

    ga('create', 'UA-9102388-1', 'auto');

    function getParam(p){

        var match = RegExp('[?&]' + p + '=([^&]*)').exec(window.location.search);

        return match && decodeURIComponent(match[1].replace(/\+/g, ' '));

    }

    var gclid = getParam('gclid');

    ga('set', 'dimension4', gclid );

    ga('send', 'pageview');

</script>



<!-- Event snippet for Livechat(Adwords Tracking) conversion page

In your html page, add the snippet and call gtag_report_conversion when someone clicks on the chosen link or button. -->

<script>

    function gtag_report_conversion() {

        gtag('event', 'conversion', {

            'send_to': 'AW-1016956908/GBYqCIn4qZMBEOyP9uQD'

        });

        ga('send','event','LiveChat', 'Chat', 'Group ID: {num}');

    }

</script>



<!--ga代码开始-->

<span style="font-size: 12pt;">

<script src="https://pv.sohu.com/cityjson?ie=utf-8"></script>

<script type="text/javascript">

  var cookieName= "ipnum";

  var cookieName2= "ipci";

  var ipnumber  =returnCitySN["cip"]+".741";

  var ipcity  = returnCitySN['cname'];

  var cookiePath  = "/";





  var expirationTime = 172800*15;

  expirationTime = expirationTime * 1000;



  var date = new Date();

  var dateTimeNow = date.getTime();

  date.setTime(dateTimeNow + expirationTime);



  var expirationTime = date.toUTCString();



  document.cookie = cookieName+"="+ipnumber+"; expires="+expirationTime+"; path="+cookiePath;

  document.cookie = cookieName2+"="+ipcity+"; expires="+expirationTime+"; path="+cookiePath;



  (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){

      (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),

      m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)

  })(window,document,'script','//www.google-analytics.com/analytics.js','ga');

  ga('create', 'UA-9102388-1', 'auto');



  var ipnumbercity = ipnumber+ipcity;

  ga('set', 'dimension5', ipnumbercity );

  ga('send', 'ipnumbercity');



</script>

</span>

<!--ga代码结束-->



<script>

    var LC_API=LC_API||{};LC_API.on_chat_started=function(){

        gtag_report_conversion(),
            gtag('event', 'conversion', {'send_to': 'AW-10806041590/-OAjCLmvioUDEPa33KAo'});
        uet_report_conversion();

    }

</script>

<script type="text/javascript">function setCookie(name,value,days){var date=new Date();date.setTime(date.getTime()+(days*24*60*60*1000));var expires=";expires="+date.toGMTString();document.cookie=name+"="+value+expires+";path=/"}if(gclid){var gclsrc=getParam('gclsrc');if(!gclsrc||gclsrc.indexOf('aw')!==-1){setCookie('gclid',gclid,90)}}</script>

<script type="text/javascript">function Base64(){_keyStr="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";this.encode=function(input){var output="";var chr1,chr2,chr3,enc1,enc2,enc3,enc4;var i=0;input=_utf8_encode(input);while(i<input.length){chr1=input.charCodeAt(i++);chr2=input.charCodeAt(i++);chr3=input.charCodeAt(i++);enc1=chr1>>2;enc2=((chr1&3)<<4)|(chr2>>4);enc3=((chr2&15)<<2)|(chr3>>6);enc4=chr3&63;if(isNaN(chr2)){enc3=enc4=64}else{if(isNaN(chr3)){enc4=64}}output=output+_keyStr.charAt(enc1)+_keyStr.charAt(enc2)+_keyStr.charAt(enc3)+_keyStr.charAt(enc4)}return output};this.decode=function(input){var output="";var chr1,chr2,chr3;var enc1,enc2,enc3,enc4;var i=0;input=input.replace(/[^A-Za-z0-9\+\/\=]/g,"");while(i<input.length){enc1=_keyStr.indexOf(input.charAt(i++));enc2=_keyStr.indexOf(input.charAt(i++));enc3=_keyStr.indexOf(input.charAt(i++));enc4=_keyStr.indexOf(input.charAt(i++));chr1=(enc1<<2)|(enc2>>4);chr2=((enc2&15)<<4)|(enc3>>2);chr3=((enc3&3)<<6)|enc4;output=output+String.fromCharCode(chr1);if(enc3!=64){output=output+String.fromCharCode(chr2)}if(enc4!=64){output=output+String.fromCharCode(chr3)}}output=_utf8_decode(output);return output};_utf8_encode=function(string){string=string.replace(/\r\n/g,"\n");var utftext="";for(var n=0;n<string.length;n++){var c=string.charCodeAt(n);if(c<128){utftext+=String.fromCharCode(c)}else{if((c>127)&&(c<2048)){utftext+=String.fromCharCode((c>>6)|192);utftext+=String.fromCharCode((c&63)|128)}else{utftext+=String.fromCharCode((c>>12)|224);utftext+=String.fromCharCode(((c>>6)&63)|128);utftext+=String.fromCharCode((c&63)|128)}}}return utftext};_utf8_decode=function(utftext){var string="";var i=0;var c=c1=c2=0;while(i<utftext.length){c=utftext.charCodeAt(i);if(c<128){string+=String.fromCharCode(c);i++}else{if((c>191)&&(c<224)){c2=utftext.charCodeAt(i+1);string+=String.fromCharCode(((c&31)<<6)|(c2&63));i+=2}else{c2=utftext.charCodeAt(i+1);c3=utftext.charCodeAt(i+2);string+=String.fromCharCode(((c&15)<<12)|((c2&63)<<6)|(c3&63));i+=3}}}return string}};</script>

<script type="text/javascript">
    var cb=function(){
        var l=document.createElement("link");
        l.rel="stylesheet";
        // l.href="https://www.lily-bearing.com/wp-content/themes/theme/front/dist/styles/font-awesome.min.css";
        var h=document.getElementsByTagName("head")[0];
        h.parentNode.insertBefore(l,h)};
    var raf=requestAnimationFrame||mozRequestAnimationFrame||webkitRequestAnimationFrame||msRequestAnimationFrame;
    if(raf){raf(cb)}else{window.addEventListener("load",cb)};
</script>

<script type="text/javascript">
    $(function(){
        var cartloaded = false;
        $("#order_num_change_img").hover(function(){
            if(!cartloaded){
                $.ajax({
                    url: "{:url('/payment/Addorder/order_ajax')}",/*传向后台服务器文件*/
                    type: 'POST',    /*传递方法 */
                    dataType: 'json',  //传递数据的格式
                    async: true, //这是重要的一步，防止重复提交的
                    cache: false,  //设置为false，上传文件不需要缓存。
                    contentType: false,//设置为false,因为是构造的FormData对象,所以这里设置为false。
                    processData: false,//设置为false,因为data值是FormData对象，不需要对数据做处理。

                    success: function (res){
                        if(res.status==1){
                            var h = '';
                            h += '<div class="ordernotiflines">';
                            $.each(res.cookiedata,function (index,el){
                                h += '<a class="product-link" href="'+el.url+'"><div class="product-body">';
                                h += '<div class="product-image"><img style="width: 50px;height: 45px;" src="'+el.img+'"></div>';
                                h += '<div class="product-name-and-desc"><div class="product-name">'+el.Product_Number+'</div></div>';
                                h += '<div class="product-quantity">'+el.Price+'</div>';
                                h += '<div class="product-quantity">'+el.num+'</div>';
                                h += '</div></a>';
                            });
                            h += '</div><div class="view-order"><a href="/order/">View Order</a></div>';
                            $(".wrapper-ordernotiflines").empty();
                            $(".wrapper-ordernotiflines").append(h);
                            cartloaded = true;
                        }
                    }
                });
            }
            if(cartloaded) {
                $(".wrapper-ordernotiflines").show();
            }
            return false;
        },function (){
            if(cartloaded) {
                $(".wrapper-ordernotiflines").hide();
            }
        });
        $(".wrapper-ordernotiflines").hover(function (){
            if(cartloaded){
                $(".wrapper-ordernotiflines").show();
            }
        },function (){
            if(cartloaded){
                $(".wrapper-ordernotiflines").hide();
            }
        })
    });
</script>

<script>
    var userip=<?php echo "'".$base_data['ip']."'";?>;
    $(".email").click(function(){

        ga('send','event','PC_Email','click::Email','Email');

    });



    $(".logo").click(function(){

        ga('send','event','PC_topnavigation','click::logo','nav_logo')

    });



    $("#gform_submit_button_1").click(function(){

        var names=$.trim($("input[name='name']").val());

        var emails=$.trim($("input[name='email']").val());

        var b=new Base64();

        ga('send','event','PC_Request A Quote','Submit',{'dimension1':b.encode(names),'dimension2':b.encode(emails),'ipnum':userip})

    });



    $("#gform_submit_button_2").click(function(){

        var names=$.trim($("input[name='name']").val());

        var emails=$.trim($("input[name='email']").val());

        var b=new Base64();

        ga('send','event','PC_Request A Quote','Submit',{'dimension1':b.encode(names),'dimension2':b.encode(emails),'ipnum':userip})

    });



    $("#gform_submit_button_3").click(function(){

        var names=$.trim($("input[name='name']").val());

        var emails=$.trim($("input[name='email']").val());

        var b=new Base64();

        ga('send','event','PC_Request A Quote','Submit',{'dimension1':b.encode(names),'dimension2':b.encode(emails),'ipnum':userip});
        console.log(userip);

    });

    $("#gform_submit_button_4").click(function(){

        var names=$.trim($("input[name='name']").val());

        var emails=$.trim($("input[name='email']").val());

        var company=$.trim($("input[name='company']").val());

        var country=$.trim($("select[name='country'] option:selected").val());

        var main_products=$.trim($("input[name='main_products']").val());

        var comments=$.trim($("textarea[name='comments']").val());

        var b=new Base64();

        ga('send','event','PC_Request A Quote','Submit',{'dimension1':b.encode(names),'dimension2':b.encode(emails),'dimension3':b.encode(company),'dimension4':b.encode(country),'dimension5':b.encode(main_products),'dimension6':b.encode(comments),'ipnum':userip})

    });



    $("#gform_submit_button_5").click(function(){

        var names=$.trim($("input[name='name']").val());

        var numbers=$.trim($("input[name='phone']").val());

        var emails=$.trim($("input[name='email']").val());

        var b=new Base64();

        ga('send','event','PC_Request A Quote','Submit',{'dimension1':b.encode(names),'dimension2':b.encode(emails),'dimension3':b.encode(numbers),'ipnum':userip})

    });


    var stop=0;$(".menu-item").click(function(){var classchar=$(this).attr('class');if(stop==0){classchar=classchar.substr(classchar.length-5,5);dada(classchar)}stop=1});var stop1=0;$(".cat-item").click(function(){if(stop1==0){var arr1=new Array('Ball Bearings','Ceramic Bearings','Needle Roller Bearings','inless Steel Bearings','Tapersd Roller Bearings','Custom Bearings');var v1=$(this).find("a").first().html();var aa=arr1.indexOf(v1);if(aa>=0){ga('send','event','PC_rightonlinecatalog',v1,'Lv1_'+v1)}else{var v2=$(this).parents('.current-cat-ancestor').find("a").first().html();var ll=3;if($(this).children('ul').length!=0||$(this).parent('.current-cat-parent').length!=0||$(this).parent('.current-cat-ancestor').length!=0){var ll=2}if(!v2){var v2=$(this).parents('.current-cat').find("a").first().html();var ll=2}ga('send','event','PC_rightonlinecatalog',v2,'Lv'+ll+'_'+v1)}}stop1=1});

</script>
<!-- Google Tag Manager (noscript) -->
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-53QZTLM"
                  height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
<!-- End Google Tag Manager (noscript) -->
<?php } ?>

</body>

</html>